"""
序列化器
"""

from rest_framework import serializers
from points_mall.models import PointsMallGoods


class PointsMallGoodsSerializer(serializers.ModelSerializer):
    """
    用户组序列化器
    """
    id = serializers.SerializerMethodField()

    class Meta:
        """
        序列化模型
        """
        model = PointsMallGoods
        fields = '__all__'

    def get_id(self, obj):
        return obj.id




